<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">
<head>
	<meta http-equiv="content-type" content="text/html; charset=UTF-8"> 
	<meta http-equiv="X-UA-Compatible" content="IE=edge">
	<title>合同管理平台 | 系统登录</title>
	<meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
	<link rel="stylesheet" href="../static/lib/bootstrap/3.3.7/css/bootstrap.min.css" th:href="@{/lib/bootstrap/3.3.7/css/bootstrap.min.css}" />
	<link rel="stylesheet" href="../static/lib/font-awesome/4.7.0/css/font-awesome.min.css" th:href="@{/lib/font-awesome/4.7.0/css/font-awesome.min.css}" />
	<link rel="stylesheet" href="../static/lib/AdminLTE/2.3.11/css/AdminLTE.min.css" th:href="@{/lib/AdminLTE/2.3.11/css/AdminLTE.min.css}" />
	<link rel="stylesheet" href="../static/css/site.css" th:href="@{/css/site.css}" />
	<!--[if lt IE 9]>
	<script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
	<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
	<![endif]-->
</head>

<body class="hold-transition login-page">
<div class="login-box">
	<div class="login-logo"><b>合同管理平台</b></div>
<div style="color:red; text-align: center;" th:text="${error}"></div>
<div class="login-box-body">
	<p class="login-box-msg">Sign in to start your session</p>
	<form id="loginForm" th:action="@{/login}" method="post">
		<input type="hidden" name="redirect" th:value="${param.redirect}" />
		<div class="form-group has-feedback">
			<input id="username" name="username" type="text" class="form-control" placeholder="用户名" data-rule-required="true" value="" data-msg-required="用户名为必输项">
			<span class="glyphicon glyphicon-user form-control-feedback"></span>
		</div>
		<div class="form-group has-feedback">
			<input id="password" name="password" type="password" class="form-control" placeholder="密码" data-rule-required="true" value="123456" data-msg-required="密码为必输项">
			<span class="glyphicon glyphicon-lock form-control-feedback"></span>
		</div>
		<div class="row">
			<div class="col-xs-12">
				<button type="submit" class="btn btn-primary btn-block btn-flat">登录</button>
			</div>
		</div>
    </form>
</div>

<script th:src="@{/lib/jquery/jquery-3.2.1.min.js}"></script>
<script th:src="@{/lib/bootstrap/3.3.7/js/bootstrap.min.js}"></script>
<script th:src="@{/lib/jquery-validation/1.16.0/jquery.validate.min.js}"></script>
<script>
$().ready(function() {
	$("#loginForm").validate({
		errorPlacement: function(error, element) {
			element.parent().append(error);
		}
	});
});
</script>
</body>
</html>
